class AppConstants {
  // 应用信息
  static const String appName = 'Game Wiki App';
  static const String appVersion = '1.0.0';
  static const String appDescription = 'A comprehensive game wiki application';

  // 默认Wiki配置
  static const String defaultWikiId = 'stardew_valley';
  static const String defaultWikiUrl = 'https://zh.stardewvalleywiki.com/Stardew_Valley_Wiki';

  // 本地存储键
  static const String keyCurrentWikiId = 'current_wiki_id';
  static const String keyCurrentWikiUrl = 'current_wiki_url';
  static const String keyUserData = 'user_data';
  static const String keyAppSettings = 'app_settings';
  static const String keySearchHistory = 'search_history';
  static const String keyFavorites = 'favorites';
  static const String keyHistory = 'history';
  static const String keyThemeMode = 'theme_mode';
  static const String keyLanguage = 'language';
  static const String keyNetworkCacheEnabled = 'network_cache_enabled';
  static const String keyNetworkOfflineMode = 'network_offline_mode';
  static const String keyRemoteConfigCache = 'remote_config_cache';
  static const String keyRemoteConfigLastUpdate = 'remote_config_last_update';
  static const String keyAutoReconnect = 'auto_reconnect';

  // 网络配置
  static const int networkTimeoutSeconds = 30;
  static const int maxRetryAttempts = 3;

  // UI配置
  static const double defaultPadding = 16.0;
  static const double smallPadding = 8.0;
  static const double largePadding = 24.0;
  static const double borderRadius = 12.0;
  static const double iconSize = 24.0;
  static const double largeIconSize = 48.0;

  // 字母索引
  static const List<String> alphabetList = [
    'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M',
    'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'
  ];

  // 动画配置
  static const Duration animationDuration = Duration(milliseconds: 300);
  static const Duration shortAnimationDuration = Duration(milliseconds: 150);
  static const Duration longAnimationDuration = Duration(milliseconds: 500);

  // WebView配置
  static const String webViewUserAgent = 'GameWikiApp/1.0.0 (Flutter)';
  static const bool webViewJavaScriptEnabled = true;
  static const bool webViewDomStorageEnabled = true;

  // 远程配置
  static const String remoteConfigUrl = 'https://api.example.com/wiki-config';
  static const Duration remoteConfigCacheExpiry = Duration(hours: 24);
  
  // 错误消息
  static const String errorNetworkConnection = '网络连接失败，请检查网络设置';
  static const String errorLoadingWiki = '加载Wiki内容失败，请稍后重试';
  static const String errorSearchFailed = '搜索失败，请稍后重试';
  static const String errorRemoteConfigFailed = '获取远程配置失败';
  static const String errorNetworkConnectionFailed = '网络连接失败';

  // 成功消息
  static const String successFavoriteAdded = '已添加到收藏';
  static const String successFavoriteRemoved = '已从收藏移除';
  static const String successHistoryCleared = '历史记录已清空';
  static const String successNetworkConnected = '网络连接成功';
  static const String successNetworkDisconnected = '网络已断开连接';
  static const String successLoginMessage = '登录成功';
  static const String successLogoutMessage = '退出登录成功';
  static const String msgHistoryRemoved = '历史记录已删除';
  static const String msgHistoryCleared = '历史记录已清空';
  static const String msgFavoriteAdded = '已添加到收藏';
  static const String msgFavoriteRemoved = '已从收藏移除';
  static const String msgFavoritesCleared = '收藏已清空';
}

